Skip to main content
This forum is closed to new posts and responses. Individual names altered for privacy purposes. The information contained in this website is provided for informational purposes only and should not be construed as a forum for customer support requests. Any customer support requests should be directed to the official HCL customer support channels below:

HCL Software Customer Support Portal for U.S. Federal Government clients
HCL Software Customer Support Portal

HCL Notes/Domino 8.5 Forum (includes Notes Traveler)

HCL Notes/Domino 8.5 Forum (includes Notes Traveler)

Previous Next

Still haven't defined scope

'2 strings inside the document'.
One field that's text or n fields that are text or RT?

Let's assume that the strings live in a single text field in your docs and let's call the field 'myTextField'.
You want to change the string 'my initial string' to 'my new string'.

The agent is as simple as:
FIELD myTextField := @ReplaceSubstring(myTextField;"my initial string";"my new string");

Set the agent to run on all all docs in a view, make sure you have a view containing all the stuff you want to change and then run the agent.

You may have to handle case but this is all pretty simple.

If the field is Rich Text...harder.
If you have 10 fields that need this change, then the code has to handle all 10 fields.
If this is something you need to do more than once with variable strings each time, you'd want to generalize the solution and use @Prompts to get the initial and final substrings (and this is more complex but we'll leave that for a different discussion).

What you do depends on the scope of the problem.

HTH


Feedback response number WEBBAC4NVV created by ~Hank Lopvelutergon on 07/22/2016

Search and Replace (~Hal Elaplopode... 21.Jul.16)
. . Depends on the scope of your proble... (~Martha Lopjipy... 22.Jul.16)
. . . . Re: (~Hal Elaplopode... 22.Jul.16)
. . . . Re: (~Hal Elaplopode... 22.Jul.16)
. . . . . . Still haven't defined scope (~Martha Lopjipy... 22.Jul.16)
. . . . Find Replace (~Hal Elaplopode... 22.Jul.16)
. . . . Keyword (~Hal Elaplopode... 22.Jul.16)
. . . . . . You're probably noticing now, there... (~Sigmund Umwema... 25.Jul.16)
. . . . . . That won't work (~Justin Chugero... 22.Jul.16)
. . . . . . . . Lotusscript not necessary (~Lily Minkitexf... 22.Jul.16)




Printer-friendly

Search this forum

Member Tools


RSS Feeds

 RSS feedsRSS
All forum posts RSS
All main topics RSS